package com.huaxin.hxmodulesystem.models;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.time.LocalDateTime;

@Data
@EqualsAndHashCode(callSuper = true)
@TableName("sys_user")
public class SysUser extends BaseModel {
    /**
     * 用户名
     */
    @TableField(value = "username")
    private String username;
    /**
     * 密码
     */
    @TableField(value = "password_hash")
    private String passwordHash;
    /**
     * 邮箱
     */
    @TableField(value = "email")
    private String email;
    /**
     * 真实姓名
     */
    @TableField(value = "real_name")
    private String realName;
    /**
     * 状态
     */
    @TableField(value = "status")
    private Integer status = 1;
    /**
     * 角色ID
     */
    @TableField(value = "role_id")
    private String roleId;
    /**
     * 最后登录时间
     */
    @TableField(value = "last_login_time")
    private LocalDateTime lastLoginTime;
    /**
     * 最后登录IP
     */
    @TableField(value = "last_login_ip")
    private String lastLoginIp;
    /**
     * 锁定时间
     */
    @TableField(value = "locked_until")
    private LocalDateTime lockedUntil;
    /**
     * 手机号
     */
    @TableField(value = "phone")
    private String phone;
}
